#include <stdio.h>
#include <stdlib.h>
#include <assert.h>
#include "dominion.h"

int values[] = {40, 10, 100, 90, 20, 25};

int compare(const void* a, const void* b);

int main(int argc, char *argv[]){

	qsort(values, 6, sizeof(int), compare);//Sort cards in deck... probably the same idea that vegas casinos use when they use a new deck of cards for each new game.

	int size = sizeof(values) / sizeof(values[0]);

	for(int n = 0; n < size; n++){
		printf("%d\n", values[n]);
	}
	int i;
	for(i = 0; i < size - 1; i++){		
		if(values[i] < values[i + 1]){
			printf("Cards in order.\n");
			printf("PASSED.\n");
		}
		else{
			printf("Cards not in order.\n");
			printf("FAILED.\n");
		}
	}
	printf("Unit Test 4 PASSED Qsort works.\n");
	return 0;
}
